<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta http-equiv="content-type" content="text/html; charset=utf-8"/>
    <meta name="renderer" content="webkit"/>
    <meta http-equiv="X-UA-Compatible" content="IE=edge,Chrome=1"/>
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"/>
    <meta name="apple-mobile-web-app-status-bar-style" content="black"/>
    <meta name="apple-mobile-web-app-capable" content="yes"/>
    <meta name="format-detection" content="telephone=no"/>
    <!--Open Sans Font [ OPTIONAL ] -->
    <link href="http://fonts.googleapis.com/css?family=Open+Sans:300,400,600,700&amp;subset=latin" rel="stylesheet"/>
    <link th:href="@{/static/plug-in/layui/css/layui.css}" rel="stylesheet" media="all"/>
    <link type="text/css" rel="stylesheet" th:href="@{/static/resources/common/css/entity.css}" media="all"/>
    <!--Themify Icons [ OPTIONAL ]-->
    <link th:href="@{/static/plug-in/icon/themify-icons/themify-icons.min.css}" rel="stylesheet"/>
    <link th:href="@{/static/plug-in/icon/plugins/ionicons/css/ionicons.min.css}" rel="stylesheet"/>
    <script th:src="@{/static/plug-in/layui/layui.js}"></script>
    <script type="text/javascript" th:src="@{/static/resources/common/js/entity.js}"></script>
</head>
<body>
<div class="layui-custom-body">
    <header class="layui-custom-header">
        <fieldset class="layui-elem-field layui-field-title">
            <!--/*@thymesVar id="title" type="com.wj.common.mvc.controller"*/-->
            <legend th:text="新增用户默认密码为000000" style="color: red"></legend>
        </fieldset>
    </header>
    <!--/*@thymesVar id="url" type="com.wj.common.mvc.controller.BaseController"*/-->
    <form class="layui-form layui-form-pane custom-form" th:action="${url}" method="post">
        <!--<input type="hidden" th:name="${_csrf.parameterName}" th:value="${_csrf.token}"/>-->
        <div class="layui-custom-domain">
            <div class="layui-custom-form">
                <div class="layui-custom-inline">
                    <div class="layui-form-item layui-custom-form-item">
                        <label class="layui-form-label">用户姓名</label>
                        <div class="layui-input-block">
                            <input type="text" name="name" th:value="${entity.name}" lay-verify="required"
                                   maxlength="50"
                                   placeholder="请输入用户姓名" autocomplete="off" class="layui-input"/>
                        </div>
                    </div>
                    <div class="layui-form-item layui-custom-form-item">
                        <label class="layui-form-label">登录账号</label>
                        <div class="layui-input-block">
                            <input type="text" name="userid" th:value="${entity.userid}" lay-verify="required"
                                   maxlength="200"
                                   placeholder="登录账号" autocomplete="off" class="layui-input"/>
                        </div>
                    </div>
                </div>
                <div class="layui-custom-inline">
                    <div class="layui-form-item layui-custom-form-item">
                        <label class="layui-form-label">所属部门</label>
                        <div class="layui-input-block">
                            <select name="orgid" lay-verify="required" lay-filter="orgid" lay-search>
                                <option value="" th:text="--请选择部门--"></option>
                                <option th:each="p:${OrgList}" th:value="${p.id}" th:text="${p.name}"
                                        th:selected="${entity.orgid == p.id}?true:false">
                                </option>
                            </select>
                        </div>
                    </div>
                    <div class="layui-form-item layui-custom-form-item">
                        <label class="layui-form-label">用户类型</label>
                        <div class="layui-input-block">
                            <select name="yhsf" lay-verify="required" lay-filter="orgid">
                                <option value="" th:text="--请选择用户类型--"></option>
                                <option th:value="1" th:text="教师" th:selected="${entity.yhsf== 1}?true:false"></option>
                                <option th:value="2" th:text="学生" th:selected="${entity.yhsf== 2}?true:false"></option>
                                <option th:value="3" th:text="其他" th:selected="${entity.yhsf== 3}?true:false"></option>
                            </select>
                        </div>
                    </div>
                </div>
                <div class="layui-custom-inline">
                    <div class="layui-form-item layui-custom-form-item">
                        <label class="layui-form-label ">状态</label>
                        <div class="layui-input-block layui-custom-input-block">
                            <input type="radio" name="state" value="0"
                                   th:title="禁用" th:checked="${1!=entity.state?true:false}"/>
                            <input type="radio" name="state" value="1"
                                   th:title="启用" th:checked="${1==entity.state?true:false}"/>
                        </div>
                    </div>
                </div>
            </div>
        </div>
        <footer class="layui-custom-footer">
            <div class="layui-custom-button" th:if="${button == true}">
                <button class="layui-btn layui-btn-small custom-save" type="button">保&nbsp;&nbsp;&nbsp;&nbsp;存</button>
                <button type="reset" class="layui-btn layui-btn-small layui-btn-primary">重&nbsp;&nbsp;&nbsp;&nbsp;置
                </button>
            </div>
        </footer>
        <input type="hidden" th:value="${entity.id}" name="id"/>
        <input type="hidden" th:value="${entity.loginnum}" name="loginnum"/>
        <input type="hidden" th:value="${entity.password}" name="password"/>
        <input type="hidden" th:value="${entity.loginip}" name="loginip"/>
        <input type="hidden" th:value="${entity.locked}" name="locked"/>
        <input type="hidden" th:value="${entity.lasttime}" name="lasttime"/>
    </form>
</div>
<input name="button" th:value="${button}" type="hidden"/>
<input name="msg" th:value="${msg}" type="hidden"/>
</body>
</html>